<?php

declare(strict_types=1);

namespace App\Controller\Api;

use Hyperf\HttpServer\Contract\RequestInterface;
use Hyperf\HttpServer\Annotation\Controller;
use Hyperf\HttpServer\Annotation\RequestMapping;
use App\Service\Code\Normal;
use App\Service\QueueService\Queue\PlaceOrderQueueProducer;

/**
 * @Controller(prefix="/GrpcService")
 * @author Administrator
 *
 */
class GrpcController
{
    /**
     * @RequestMapping(path="sayHelloWorld", methods="get")
     * @return string[]
     */
    public function sayHelloWorld(RequestInterface $request,PlaceOrderQueueProducer $PlaceOrderQueueProducer)
    {
        $PlaceOrderQueueProducer->push(Normal::returnCode(Normal::SUC,"发布成功"));
        return Normal::returnCode(Normal::SUC,"发布成功");
    }
}
